package org.wattdepot.cli;

import junit.framework.Assert;
import org.junit.Before;
import org.junit.Test;
/**
 * Tests the carbon content module.
 * 
 * @author Aaron Herres
 * 
 */
public class TestCarbonContent {
  CommandLineInterface cli;

  /**
   * Initialises class for testing.
   */
  @Before
  public void initializeCommandLineInterface() {
    cli = new CommandLineInterface("http://server.wattdepot.org:8182/wattdepot/");
  }

  /**
   * Tests the carbon content by timestamp.
   */
  @Test
  public void testCarbonContent() {

    String message =
        cli.processMainCommand(
            "carboncontent SIM_IPP 2009-11-15T12:00:00.000-10:00 sampling-interval 10");
    System.out.println(message);
    Assert.assertNotNull(message);
  }
}
